package com.spark.localvector

import org.apache.spark.mllib.linalg.Matrices

/**
  * Created by Administrator on 2017/8/21.
  */
object localMatrix {
  def main(args: Array[String]): Unit = {

    val dm1=Matrices.dense(3,2,Array(1.0,3.0,5.0,2.0,4.0,6.0))
    val dm2=Matrices.sparse(3,2,Array(0,1,3),Array(0,2,1),Array(0,6,8))

    println(dm1)
    println(dm2)


  }

}
